#pragma once
#include "Common.h"
class ThreadCache
{
public:
	void* setAlloc(size_t size);
	void  deAlloc(void* ptr, size_t size);
	void* FetchfromcentralCache(size_t index, size_t size);
	void  listtoolong(freelist* list, size_t size);
private:
	 freelist _freelist[NFREELIST];
	
};
static _declspec(thread) ThreadCache* pTLSThreadCache = nullptr;    //让线程间互不干扰